<!-- 公共头部 -->
<%- include ../public/page_header.html %>


           
    <div class="panel panel-default">
        <div class="panel-heading">
            搜索
        </div>
        <div class="panel-body">
            <form role="form" class="form-inline">
                <div class="form-group">
                    <label for="name">名称</label>
                    <input type="text" class="form-control" id="name" placeholder="请输入名称">
                </div>

                <div class="form-group">
                    <button type="submit" class="btn btn-default">开始搜索</button>
                </div>
            </form>
        </div>
    </div>
    <!--
        列表展示
    -->
    <div class="table-responsive">
        <table class="table table-bordered">
            <thead>
                <tr class="th">
                    <th>管理员名称</th>
                    <th>管理员电话</th>
                    <th>管理员邮箱</th>
                    <th>管理员角色</th>
                    <th>状态</th>
                    <th class="text-center">操作</th>
                </tr>
            </thead>
            <tbody>
                <% for(var i=0;i<list.length;i++) { %>
                <tr>
                    <td><%= list[i].username %></td>
                    <td><%= list[i].mobile %></td>
                    <td><%= list[i].email %></td>
                    <td><%= list[i].role[0].title %></td>

                    <td class="test-center">
                        <% if(list[i].status ==1 ) { %>
                            <img src="/public/admin/images/yes.gif" onclick="app.changeStatus(this, 'Admin', 'status', '<%=list[i]._id%>')"/>
                        <% } else { %>
                            <img src="/public/admin/images/no.gif" onclick="app.changeStatus(this, 'Admin', 'status', '<%=list[i]._id%>')"/>
                        <% } %>
                    </td>

                    <td class="text-center">                                
                        <a href="/admin/manager/edit?id=<%= list[i]._id %>">修改</a>   &nbsp; &nbsp;
                        <a class="delete" href="/admin/delete?id=<%= list[i]._id %>&model=Admin">删除</a>
                    </td>
                </tr>
                <% } %>
            </tbody>
        </table>
    </div>


</body>
</html>